package Servlet;

import java.io.IOException;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import Info.CustomerInfo;
import Manage.CustomerManage;


public class UpdateCustomerServlet extends HttpServlet{
	protected void service(HttpServletRequest request, HttpServletResponse response) 
			throws ServletException, IOException {
	request.setCharacterEncoding("utf-8");
	response.setContentType("text/html;charset=utf-8");
	int cid = Integer.parseInt(request.getParameter("cid"));
	CustomerManage customerm = new CustomerManage();
	CustomerInfo c = customerm.FindCid(cid);
	request.setAttribute("c", c);
	request.getRequestDispatcher("UpdateCustomer.jsp").forward(request, response);
	}
}
